import React from "react";
import LayoutComponent from "../../layout";
import { RouteItem } from "../interface/route-item.interface";
import lazyLoad from "../utils/lazy-load";

// dashboard 模块
const dashboardRouter: Array<RouteItem> = [
	{
		path: 'dashboard',
		element: <LayoutComponent />,
		meta: {
			title: "Dashboard"
		},
		children: [
			{
				path: "/dashboard/index",
				element: lazyLoad(React.lazy(() => import("../../views/dashboard/index"))),
				meta: {
					requiresAuth: true,
					title: "首页",
					key: "dataVisualize"
				}
			}
		]
	}
];

export default dashboardRouter;
